package test5;

public class RoleTest {
    public static void main(String[] args) {
        Role qf = new Role("乔峰",100);
        Role jmz = new Role("鸠摩智",100);

        while (true){
            qf.attack(jmz);
            if (jmz.getBlood()==0){
                System.out.println(qf.getName()+"击败了"+jmz.getName());
                break;
            }

            jmz.attack(qf);
            if(qf.getBlood()==0){
                System.out.println(jmz.getName()+"击败了"+qf.getName());
                break;
            }
        }
    }
}
